﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="speakDemo.aspx.cs" Inherits="stwh_Web.speakDemo" %>

<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <title></title>
    <cms:stwhbtlink ID="stwhbtlink" runat="server" />
</head>
<body>
    <div class="container">
        <textarea id="neirong" style="width:400px; height:200px;"></textarea>
        <div id="speech1" class="btn btn-default">朗读</div>
        <div id="speech2" class="btn btn-default">停止</div>
    </div>
    <cms:stwhbtscript ID="stwhbtscript" runat="server" />
    <script type="text/javascript">
        $(function () {
            $("#speech1").click(function () {
                $.post("/handler/speech.ashx", {
                    "type":0,
                    "text": $("#neirong").val()
                }, function (data) {

                }, "text");
            });
            $("#speech2").click(function () {
                $.post("/handler/speech.ashx", {
                    "type": 1
                }, function (data) {

                }, "text");
            });
        });
    </script>
    <asp:Literal ID="LiteralJS" runat="server"></asp:Literal>
</body>
</html>